package cn.com.hbhgkj;

public enum ReviewCode {
	PASS(2), FAIL(4),PENDING_REVIEW(1);

	public static ReviewCode valueOf(int value) {
		ReviewCode result = null;
		for(ReviewCode each : ReviewCode.values()){
			if(each.getValue() == value){
				result = each;
				break;
			}
		}
		
		return result;
	}
	
	public static boolean isPass(int value){
		return ReviewCode.PASS.getValue() == value;
	}

	private int value;

	ReviewCode(int value) {
		this.value = value;
	}

	public int getValue() {
		return value;
	}

	public void setValue(int value) {
		this.value = value;
	}

}
